#ifndef GS_PLAY_H
#define GS_PLAY_H
#include "GameCore\GameState.h"
#include "GameCore\Camera.h"
#include "GameCore\Shader.h"
#include "GameCore\sprite.h"
#include "GameObjects\GameObject2D.h"
#include "GameCore\RenderTarget.h"
#include "btBulletDynamicsCommon.h"
#include <vector>
#include "GameObjects\GameObject3DPhysics.h"
//------------------------------------

//------------------------------------
class GS_Play : public GameState
{
public:
	virtual void Init();

	virtual bool PostInit(int& step)
	{
		return true;
	}
	virtual void Release();

	virtual void Update(float timeTotal, float timeDelta);

	virtual void Render();

	virtual void OnTouchDown(unsigned int id, float x, float y);
	virtual void OnTouchUp(unsigned int id, float x, float y);
	virtual void OnTouchMove(unsigned int id, float x, float y);
protected:
	Camera* camera;
	Program *simpleProgram;
	Program *fireworkProgram;
	Texture *Kaleidoscopes;
	Sprite* spriteDog;
	GameObject2D* dog;
	RenderTarget* renderTarget;
	VBO* vboKaleidoscopes;
	int vertexCount;
	void InitPhysics();
	void CleanupPhysics();
	btRigidBody* sphereDog;
	btRigidBody* boxTest;
	std::vector<GameObject3DPhysics*> object3Ds;
	void InitObject3Ds();
};
#endif